package com.fiidee.blog.mapper;

import com.fiidee.blog.dto.BlogDTO;
import com.fiidee.blog.entity.Blog;
import com.fiidee.blog.entity.BlogData;
import org.apache.http.HttpResponse;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface BlogMapper {
    int deleteByPrimaryKey(Integer id);

    int insert(Blog record);

    int insertSelective(Blog record);

    Blog selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(Blog record);


    int updateByPrimaryKey(Blog record);

    List<Blog> selectByDTO(@Param("dto") BlogDTO dto);

    int deleteInIds(@Param("ids") String ids);

    int countHomeList(@Param("dto") BlogDTO dto);

    List<Map<String, Object>> selectHomeList(@Param("dto") BlogDTO dto, @Param("index") Integer index, @Param("rows") Integer rows);

    List<Map<String, Object>> selectRecommendList();

    Map<String,Object> getArroundBlog(@Param("id") Integer id);

    Map<String, Object> getBlogContent(@Param("id") Integer id);
}